package com.jxin.mall.weixin.domain.entity.service;

import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

/**
 * 图灵接口响应正文类
 * @author  蔡佳新
 * @version 1.0
 * @since   jdk 1.8
 */
@Data
@NoArgsConstructor
public class TuLingResponseBody implements Serializable {

    private static final long serialVersionUID = 5932211735706291490L;
    private Intent intent;
    private List<Results> results;
    private Intent intentX;


    @NoArgsConstructor
    @Data
    public static class Intent {
        /**意图动作名称*/
        private String actionName;
        /**编码*/
        private int code;
        /**意图名称*/
        private String intentName;
        /**功能相关参数*/
        private Parameters parameters;
        @NoArgsConstructor
        @Data
        public static class Parameters {
            private Map<String, Object> map;
        }
    }

    @NoArgsConstructor
    @Data
    public static class Results {
        /**
         *  ‘组’编号:0为独立输出，大于0时可能包含同组相关内容 (如：音频与文本为一组时说明内容一致)
         */
        private int groupType;
        /**输出类型*/
        private String resultType;
        /**输出值*/
        private Values values;

        @NoArgsConstructor
        @Data
        public static class Values {
            /**正文*/
            private String text;
        }
    }

}
